System resource conflict resolution apparatus

ABSTRACT

A system resource enable apparatus for enabling operations on a system resource including a register representing current and future operations on the resource, a pattern generator that applies a pattern corresponding to a requested resource operation to each of a plurality of requests for resource operations in a queue, compare logic that determines for each of the plurality of requests if the request will conflict with other resource operations by comparing the pattern applied to the request with the register, priority grant logic that grants priority to a request in the queue if no conflict is determined and to update the register according to the pattern applied to the request, and resource enable logic that enables operations on the resource according to the register.

CROSS-REFERENCE TO RELATED APPLICATIONS

This patent application is a divisional of U.S. patent application Ser.No. 08/414,856 entitled SYSTEM RESOURCE ENABLE APPARATUS which was filedon Mar. 31, 1995, in the names of Patrick J. Meaney and Adrian E.Seigler.

BACKGROUND OF THE INVENTION

The present invention relates to controls for system resources and, moreparticularly, to controls for shared system resources providing forpower conservation.

In semiconductor chips with large cache arrays, a substantial amount ofthe available power is used by the array. In one attempt to reduce arraypower consumption, lower-power array cells have been utilized. Suchlow-power array cells, however, may degrade system performance.

In another attempt to reduce array power consumption, arrays have beendesigned which allow the clock input to be shut off providing an array"standby" mode. These arrays, however, often suffer performancedegradation resulting from turning on the array in the cycle that it isneeded.

In the prior art is U.S. Pat. No. 5,339,445 to Gasztonyi which describesa further attempt to reduce array power consumption. Gasztonyi maintainsa data table with historical information on power consumption and usesthe data to regulate power for future operations. Operating onhistorical data, however, can lead to inaccuracies in power applicationand correspondingly to inefficient operation of the array.

Thus, there is a need in the art for a method and apparatus forcontrolling power application to an array that conserves power whileoptimizing array performance.

SUMMARY OF THE INVENTION

With the foregoing in mind, it is an object of the invention to providea method and apparatus for controlling energization of an array so as tooptimize system performance.

In accordance with the invention, an array enable line is provided tothe array which provides the ability to disable the system clock. If thearray enable is low, the clock signal is not provided to the array,leaving the array in standby mode, and array power consumption isreduced.

The array remains in standby mode during non-use cycles. Using arrayenable logic, the array is switched on at least one cycle before thearray is to be used. Thus, performance degradation is minimized becausethe array is energized prior to array operations being performed.

Thus, the invention provides lower array power consumption withoutperformance degradation typically found in prior power reductiontechniques. Additionally, since the array enable logic operates basedupon available resource information, the array enable logic may beadapted to accomodate different power modes of operation.

BRIEF DESCRIPTION OF THE DRAWINGS

The accompanying drawings, referred to herein and constituting a parthereof, illustrate preferred embodiments of the invention and, togetherwith the description, serve to explain the principles of the invention,wherein:

FIG. 1 illustrates an array provided with an array enable line inaccordance with the invention;

FIG. 2 shows an example of a pipelined request queue;

FIG. 3 illustrates a request being presented to the array enable logic;

FIGS. 4a and 4b illustrate a preferred implementation of the arrayenable logic in accordance with the invention;

FIG. 5 illustrates pattern masks for various operational requests;

FIG. 6 illustrates an interleave register configuration for a line fetchoperation; and

FIG. 7 illustrates an interleave register configuration for a doubleword store operation.

DETAILED DESCRIPTION OF THE DRAWINGS

As described hereinafter, the resource enable apparatus according to theinvention is applied to a random access memory array. It will beappreciated that the enable apparatus is equally applicable to othersystem resouces including dedicated logic.

FIG. 1 illustrates a random access memory (RAM) array 10 with an inputregister 12 for incoming data and an output register 14 for outgoingdata. For purposes of the discussion herein, the array may be consideredas a two-dimensional array, the width of the array being the same as anincoming data word. An address register 16 is provided for selectingword lines in the array. Clock and write enable lines 18, 20,respectively, are also provided. In accordance with the invention, anarray enable line 22 which enables/disables clock line 18 is alsoprovided. It will be appreciated that the array described may actuallycomprise multiple arrays.

FIG. 2 illustrates a pipeline (serialized) request queue wherein anumber "n" of requestors 24 present requests on request bus 26 and onerequest is selected and permitted access to the pipeline in accordancewith priority logic 78 and request selector 28. It may be appreciatedthat any number of requestors may be vying for priority to gain accessto the pipeline at a given time and it is priority logic 78 and requestselector 28 that decide which one of requestors 24 will be grantedaccess.

Array enable logic 30 is also provided, in parallel with priority logic78 and request selector 28, which, in addition to looking at theidentity of the requestor, makes a determination about whether or notthat requestor will need to use array 10 and, if so, for how manycycles. Thus, at the same time that a decision is being made as towhether a requestor will gain access to pipeline, information is alsobeing compiled about if, when, and for how long that requestor will needto use array 10 in order to turn the array enable line 22 on and off.Priority may be given to a particular requestor, but since the array isto be used starting at cycle m for a duration of d+1 cycles, then thearray enable line is turned on at least one cycle prior to cycle m.

As preferably embodied, array 10 is in standby mode when array enableline 22 is not active. By turning on the array enable line at theoptimal time, performance losses are minimized by precharging of thearray. It will be appreciated that this arrangement provides the abilityto adapt to any duration or starting point according to systemrequirements. Preferably, the array enable line is turned on one cycleprior to the array being needed.

As shown by the dotted line in FIG. 2, array enable line 22 is turned onin the m-1 cycle so that the array will be ready for use by therequestor in cycle m as illustrated by the solid line. The array enableline will then stay turned on for d cycles after the m cycle for a totalof d+1 cycles, or until cycle m+d.

It may be appreciated that without array enable logic 30, if a requestorstarted to use the array from the cycle that the array was needed, acertain amount of time would be taken off the operation even though thearray may still adequately function. That first cycle would be slowerand system performance would be degraded by such slower array operation.

As shown in FIG. 3, the input to array enable logic 30 for a particularrequestor includes array needed line 32, address line 34, and operationline 36. As will be seen below, one address bit for address line 34 maybe all that is required. At the start of priority selection, arrayenable logic 30 sees the input lines and recognizes that the requestorneeds the array, e.g., for a line fetch operation. Using a register 38that represents the operational status of the array for current andfuture cycles, array enable logic 30 then makes a determination as towhether there is a contention downstream, i.e., at the time that therequested array operation is to be done there will be a conflict withother anticipated array operations. This is to prevent, for example, aprior requestor attempting use the same array at the same time as thecurrent requestor, in which case results would be unpredictable andcontrol would be lost.

The array enable logic provides a "no conflict" line 40. If the noconflict line is "1", then the request presents no problem; if the noconflict line is "0", then the request for priority will continue untilsuch time as the no conflict line is "1".

FIGS. 4a and 4b illustrate a preferred implementation of the arrayenable logic in accordance with the invention. In FIG. 4a, a singleinterleave implementation is shown with requests from a number "n"requestors coming in on request buses 42 to pattern generator 44, whichgenerates a pattern corresponding to each request, for output on patternbuses 46. Details of the pattern generator are discussed in more detailbelow. The output of interleave register 48 and pattern buses 46 areconnected through Bit-AND's 50 and, where any bit in interleave register48 is zero, the corresponding output of Bit-AND 50 will be zero.

As an example, if four bits in interleave register 48 corresponding tocycles where the generated pattern indicates that interleave access willbe required are zeros, then all of the output bits of Bit-AND 50 will bezeros. Similarly, if any of the four bits corresponding to cycles wherethe generated pattern indicates that interleave access will be requiredare ones, then at least one of the output bits of Bit-AND 50 will be aone representing a conflict. The outputs of each of the Bit-AND's 50connected through OR's 52 providing an indication on conflict lines 54of whether a conflict exists for that requestor against the interleave.

Pattern selector 56 selects one of the patterns on pattern lines 46 andoutputs the pattern to OR 58. The grant bus 60 input to pattern selector56 is from priority selection logic 62 which is described in more detailbelow.

The pattern from pattern selector 56 and the output of the interleaveregister 48 are connected throught Bit-OR 58 and shift left 64. Thus,the output of Bit-OR 58 represents the status of the interleave on thecurrent cycle, and the output of shift left 64 represents the status ofthe interleave one cycle in the future.

The output of the shift left 64, i.e., the overflow, represents thestatus of the interleave two cycles before the array is to be used andis stored in stage one register 66. The output of stage one register 66represents one cycle before the array is to be used.

Stage two register 68 represents one cycle later than the stage oneregister, due to the extra cycle of staging, and thereby represents thecurrent cycle. The outputs of stage one register 66 and stage tworegister 68 are connected through OR 70 allowing the array to be turnedon one cycle early and be maintained through the current cycle via arrayenable line 72. The array will turn off the cycle after there are nomore array operations.

As shown in FIG. 4b, the priority selection logic 62 has as inputs thesame requests from a number "n" requestors coming in on request buses 42as in FIG. 4a. As illustrated in the figure, however, there are now twointerleaves; interleave 0 and interleave 1, and the logic for eachinterleave is implemented as shown in FIG. 4a above.

Also input to priority selection logic 62 are conflict buses 54 for eachof interleave 0 and interleave 1. The conflict buses for interleave 0and interleave 1 are connected through NOR's 74, the output of which arethe m connected through AND's 76 along with request buses 42. The outputof each NOR 74 provides that if either interleave has a conflict, thenthe output of the NOR is zero and the request is ultimately barred fromgetting priority. The output of AND's 76 will be a one only if there isa request for which both interleave inputs were zero, representing arequest with no conflict. The outputs of the AND's 76 are then used todetermine which request is selected by priority logic 78, e.g., roundrobin priority logic. The output of the priority logic goes to grant bus60 for use in the interleave conflict determination.

A table of patterns provided by the pattern generator 44 is used todetermine if an interleave conflict exists as shown in FIG. 5. For agiven request type, if the interleave register in the array enable logicis zero for all one's in the table, then no interleave conflict existsfor the request.

As described above, within array enable logic 30 is a set of interleaveregisters 48 as shown in FIGS. 6 and 7. Interleave registers 48represent future state of the array (cycles C2-C9) and thereby provide amask against which a compare can be made for a requestor desiring aparticular resource at some future time. The contents of interleaveregister 48 are compared to a pattern representing the particularoperation that the requestor is desiring to determine if a conflictexists.

FIG. 6 illustrates a line fetch operation wherein ILV0 and ILV1 indicateinterleave addresses. Either interleave 0 (ILV0) or interleave 1 (ILV1)is selected via the address line. Alignment is such that, if broken downinto quad words (16 bytes), a line is eight quad words. Interleaves arearranged on a quad word address basis so there are eight quad words. Incycle 0 (the current cycle), a request for priority is made. The arrayenable logic knows that all line fetches start on cycle C2 once therequest has gained priority and, because there are eight quad words inthe line, the line fetch will take eight cycles to complete. Thus, whena request for a line fetch operation from interleave 0 is made in cycle0, the ILV0 interleave register is compared to the prestored pattern fora line fetch operation and a busy condition is indicated in cycles C2,C4, C6, and C8.

Thus, as illustrated in FIG. 6, at cycle C0 the request comes in and thearray will start to get busy in cycle C2 and will be busy for eightcycles. Thus, in cycle C2 a "1" indicates that logically the array isbusy. It may be appreciated that in reality what happens is that thereare actually two interleaves which together comprise the logical array.In the first cycle of the line fetch operation, cycle C2, the first quadword will be fetched from the first interleave ILV0 and in the nextcycle, cycle C3, the second quad word in the line will be fetched fromthe second interleave ILV1. Thus, there are two physical arrays, one foreach interleave.

With each passing cycle, the interleave registers in the array enablelogic get updated. Clock cycles continue to pass and eventually the linefetch operation is completed. In FIG. 6, this is represented by shiftingthe 1's in the interleave register to the left every cycle so thateventually, after eight cycles, all of the 1's have been shifted out ofthe interleave register.

FIG. 7 similarly illustrates a double word store operation. The arraystandby logic knows that for a single double word store operation theonly busy cycle is cycle C4. If the double word store request getspriority in the pipeline, the requestor will need to use the array oncycle C4 and will only need one cycle to complete the operation.

Thus, if the interleave register maintained within the array enablelogic was as shown in FIG. 7 at the time that a double word storeoperation on interleave ILV0 was requested, the array enable logic wouldrecognize that interleave ILV0 would be needed on cycle C4 but thatthere exists a conflict with an anticipated operation. Therefore, the noconflict line is "0" and the requestor is not granted priority into thepipeline. On the other hand, if the requestor wanted to use interleaveILV1, no conflict would exist because there is no anticipated operationon interleave ILV1 in cycle C4.

It may be appreciated that line fetch and double word store operationscould be done simultaneously because they are not operating on the samephysical array. Logically, however, it may appear that they are bothreading and writing at the same time. For example, if the double wordstore in FIG. 7 started one cycle after the line fetch in FIG. 6, thenthe C4 write to interleave ILV0 would line up with the C5 read frominterleave ILV1. Therefore, no conflict would exist between the store tointerleave ILV0 and the fetch from interleave ILV1.

Advantageously, the array enable logic according to the invention allowshandling of almost any predetermined combination of conflicts that couldoccur in the future by simply changing the pattern generation logic. Allthat need be done is to generate a pattern corresponding to the futureevent for the interleave register to check against.

The array enable logic according the invention may also be adapted tohandle possible rejects. Instead of having a single ILV0 interleaveregister, there would be more than one. One register may be provided perrequestor, with corresponding OR's and shift left's as in FIG. 4a, thenall registers could be ORed together to provide a bus that is used forthe compare logic. The shift left overflows could be ORed to provide astaging signal. If there was a reject of a particular requestor at anypoint in time, its corresponding interleave register could be zeroed outfreeing up all the possible interleaves that were blocked.

The array standby logic also need not work off the shift left bit thatoverflows as the logic may also work off an intermediate bit somewherein the interleave register to predict not only one cycle in the futurebut possibly two or more depending on how much the logic is intended tolead the current cycle. Further, the array enable logic could beextended beyond two stages if it is desired to have the array stay onfor additional cycles.

While the invention has been described in its preferred embodiments, itis to be understood that the words which have been used are words ofdescription, rather than limitation, and that changes may be made withinthe purview of the appended claims without departing from the true scopeand spirit of the invention in its broader aspects. For example,although called described in terms of clock cycles, the invention couldalso be implemented in a continuous non-clocked pipeline. Further, ifthere exists a requirement to periodically "wake up" the array duringextended periods of non-use, such wake-up facilities may be added to thesystem resource enable apparatus described herein.

What is claimed:
 1. An apparatus for establishing priority among aplurarlity of requests for resource operations on a system resource,comprising:a register representing current and future operations on theresource; a pattern source that generates a pattern corresponding to arequested resource operation for each of a plurality of requests forresource operations in a queue; compare logic that determines for eachof said plurality of requests if the request will conflict with otherresource operations by comparing the pattern generated for the requestwith said register; and priority logic that grants priority to a requestin the queue if no conflict is determined and to update said registeraccording to the pattern generated for the request.
 2. An apparatus inaccordance with claim 1, wherein the system resource is an array.
 3. Anapparatus in accordance with claim 2, wherein said array furthercomprises interleaves.
 4. An apparatus in accordance with claim 1,wherein the system resource is dedicated logic.
 5. An apparatus inaccordance with claim 1, wherein the system resource includes a standbymode.
 6. An apparatus in accordance with claim 1, wherein contents ofsaid register is left shifted on each cycle.
 7. An apparatus forestablishing priority among a plurarlity of requests for resourceoperations on a system resource, comprising:means for representingcurrent and future operations on the resource; means for generating apattern corresponding to a requested resource operation for each of aplurality of requests for resource operations in a queue; means fordetermining for each of said plurality of requests if the request willconflict with other resource operations by comparing the patterngenerated for the request with said register; and means for grantingpriority to a request in the queue if no conflict is determined and toupdate said register according to the pattern generated for the request.8. An apparatus in accordance with claim 7, wherein the system resourceis an array.
 9. An apparatus in accordance with claim 8, wherein saidarray further comprises interleaves.
 10. An apparatus in accordance withclaim 7, wherein the system resource is dedicated logic.
 11. Anapparatus in accordance with claim 7, wherein the system resourceincludes a standby mode.
 12. An apparatus in accordance with claim 7,wherein said means for representing is updated on each cycle.